﻿using System;
using System.IO;
using System.Reflection;

class cob
{
    public string type { get; set; }
    public uint obj_partindex {get; set;}
    public uint obj_clan { get; set; }
    public uint obj_sex { get; set; }
    public uint unknown1 {get; set;}
    public uint render_type { get; set; }
    public uint unknown2 { get; set; }
    public String template_guid { get; set; }
    public uint prop_category {get; set;}
    public uint uknown3 { get; set; }
    public uint shadow_type { get; set; }
    public Single sel_cube {get; set;}
    public Single dead_cube { get; set; }
    public Single visible_cube { get; set; }
    public Single collide_cube { get; set; }
    public uint effpos_list_size { get; set; }

    public void ReadFile(BinaryReader br)
    {
        this.type = SFM.BytesToString(br.ReadBytes(4));
        this.obj_partindex = br.ReadUInt32();
        this.obj_clan = br.ReadByte();
        this.obj_sex = br.ReadByte();
        this.unknown1 = br.ReadUInt16();
        this.render_type = br.ReadByte();
        this.unknown2 = br.ReadByte();
        this.template_guid = Convert.ToBase64String(br.ReadBytes(16));
        this.prop_category = br.ReadByte();
        this.uknown3 = br.ReadByte();
        this.shadow_type = br.ReadByte();
        this.sel_cube = br.ReadSingle();
        this.dead_cube = br.ReadSingle();
        this.visible_cube = br.ReadSingle();
        this.collide_cube = br.ReadSingle();
    }


}